<?xml version="1.0" encoding="UTF-8"?>
<!--
To change this template, choose Tools | Templates
and open the template in the editor.
-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:p="http://primefaces.prime.com.tr/ui">

    <body>
        <div class="post">

            <h2 class="title">Cadastro de Arquivo</h2>

            <h:panelGroup id="painelMensagens" layout="block">
                <h:messages errorStyle="color: red" infoStyle="color: green" layout="table"/>
            </h:panelGroup>

            <div id="stylized" class="myform">

                <h:form>

                    <table>

                        <tr>
                            <th><h:outputLabel>Nome: </h:outputLabel></th>
                            <td><h:outputText  value="#{UserController.user.nome}"  /></td>
                        </tr>
                        <tr>
                            <th><h:outputLabel>E-Mail: </h:outputLabel></th>
                            <td><h:outputText  value="#{UserController.user.email}"  /></td>
                        </tr>
                        <tr>
                            <th><h:outputLabel>Login: </h:outputLabel></th>
                            <td><h:outputText value="#{UserController.user.login}" /></td>
                        </tr>
                        <tr>
                            <th><h:outputLabel>Grupo: </h:outputLabel></th>
                            <td><h:outputText  value="#{UserController.user.grupo.nome}" /></td>
                        </tr>
                        <tr>
                            <th><h:outputLabel>Situação: </h:outputLabel></th>
                            <td>
                                <h:outputText value="Ativo" rendered="#{UserController.user.ativo}" />
                                <h:outputText value="Inativo" rendered="#{!UserController.user.ativo}" />
                            </td>
                        </tr>

                    </table>

                    <h:commandButton styleClass="button" action="#{UserController.novo}" value="Novo" />
                    <h:commandButton styleClass="button" action="#{PageManager.setPageCadUsuario}" value="Editar" />
                    <h:commandButton styleClass="button" action="#{UserController.destroy}" value="Remover" />

                </h:form>
            </div>
        </div>
    </body>
</html>
